import type { CommonListItem } from '@/api/common/common.d';
import type { CallBackData } from '@/components/dialog/type';
import type { PropType } from "vue";

declare interface CallBack {
  flag: boolean;
  status: string;
}

const VisibileFunc = (data: CallBackData): void => {};
const CancelFunc = (): void => {};
const SubmitFunc = (data: CallBack): void => {};
type VisibileFunc<T> = () => void;
type CancelFunc = () => void;
type SubmitFunc<T> = (data: CallBack) => void;

export default {
  radioVisible: {
    type: Boolean,
    default: true,
  },
  radioChecked: {
    type: Boolean || undefined,
    default: undefined,
  },
  handleRadioClick: {
    type: Function,
    default: () => {},
  },
  markScrapVisible: {
    type: Boolean,
    default: false
  },
  scrapList: {
    type: Array<CommonListItem>
  },
  scrapValue: {
    type: String,
    default: ''
  },
  discardRemark: {
    type: String,
    default: ''
  },
  handleMarkDesert: {
    type: Function,
    default: () => {}
  },
  handleSubmit: {
    type: Function,
    default: () => {}
  },
  handleMarkScrapVisible: {
    type: VisibileFunc as PropType<VisibileFunc<CallBackData>>,
    default: VisibileFunc
  },
  submitVisible: {
    type: Boolean,
    default: false
  },
  handleCancel: {
    type: CancelFunc as PropType<CancelFunc>,
    default: CancelFunc
  },
  handleSubmitVisible: {
    type: SubmitFunc as PropType<SubmitFunc<CallBack>>,
    default: SubmitFunc
  },
  sectionVisible: {
    type: Boolean,
    default: false
  },
  handleSectionVisible: {
    type: VisibileFunc as PropType<VisibileFunc<CallBackData>>,
    default: VisibileFunc
  },
  handlePrevClick: {
    type: Function,
    default: () => {}
  },
  handleNextClick: {
    type: Function,
    default: () => {}
  }
}